import type { App } from "vue";
const directive:any = import.meta.glob('./*.ts')
const directives = {
    install :(app:App)=>{
        Object.keys(directive).forEach((url:string)=>{
            const pathname = url?.split('/')?.pop()?.split('.ts')[0] as string;
            directive[url]().then((mod:{default:any})=>{
                app.directive(pathname,mod.default)
            })
        })
    }
}

export default directives